From e0a4694418b057255352094571d7b59a2cbc4c8b Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Thu, 5 Aug 2010 14:41:14 +0100 Subject: [PATCH] x86: Fix NMI injection to PV guests Signed-off-by: Juergen Gross --- xen/arch/x86/x86_32/entry.S | 2 +- xen/arch/x86/x86_64/compat/entry.S | 2 +- xen/arch/x86/x86_64/entry.S | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/arch/x86/x86_32/entry.S b/xen/arch/x86/x86_32/entry.S index 57915e295e..46c1f9452c 100644 --- a/xen/arch/x86/x86_32/entry.S +++ b/xen/arch/x86/x86_32/entry.S @@ -264,7 +264,7 @@ process_mce: ALIGN /* %ebx: struct vcpu */ process_nmi: - cmpw $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%ebx) + testb $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%ebx) jnz test_guest_events sti movb $0,VCPU_nmi_pending(%ebx) diff --git a/xen/arch/x86/x86_64/compat/entry.S b/xen/arch/x86/x86_64/compat/entry.S index 06581f0934..d668822cbb 100644 --- a/xen/arch/x86/x86_64/compat/entry.S +++ b/xen/arch/x86/x86_64/compat/entry.S @@ -137,7 +137,7 @@ compat_process_mce: ALIGN /* %rbx: struct vcpu */ compat_process_nmi: - cmpw $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%rbx) + testb $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%rbx) jnz compat_test_guest_events sti movb $0,VCPU_nmi_pending(%rbx) diff --git a/xen/arch/x86/x86_64/entry.S b/xen/arch/x86/x86_64/entry.S index 8bb3e228c1..05290484ec 100644 --- a/xen/arch/x86/x86_64/entry.S +++ b/xen/arch/x86/x86_64/entry.S @@ -239,7 +239,7 @@ process_mce: ALIGN /* %rbx: struct vcpu */ process_nmi: - cmpw $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%rbx) + testb $1 << VCPU_TRAP_NMI,VCPU_async_exception_mask(%rbx) jnz test_guest_events sti movb $0,VCPU_nmi_pending(%rbx) -- 2.30.2